Add support for custom headers in input processing#1561
Merged
Conversation
mre
commented
Nov 7, 2024
cd2833b to
4b08e3e
Compare
thomas-zahner
requested changes
Apr 4, 2025
Member
thomas-zahner
left a comment
There was a problem hiding this comment.
@mre I think this PR still needs some polishing to do. Also there are merge conflicts by now
Member
Author
lychee -u "Agent1" http://127.0.0.1:8082 |
The new header separator is `:`, similar to what curl uses.
… conversion from Vec of header pairs
81f123a to
e8495b5
Compare
5ec0ba4 to
06f89bb
Compare
9fa094f to
281be4d
Compare
Member
Author
|
@thomas-zahner, this is ready for another review. 😊 |
This was referenced May 23, 2025
Closed
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Previously, we didn't pass (auth) headers to the initial set of inputs -- only to the links which were discovered in the initial input set. That's inconsistent and led to some confusion.
This PR fixes that. There is probably a nicer design for input parsing; the constructor has quite a few "dummy" params now, which tend to be set to the same values. I guess we can refactor that to, say, introduce the notion of an
InputBuilderif it becomes to tedious to set these values. I guess we should decouple input parsing for the different input types in general because header handling is only needed for web requests and not for file inputs.For now, I just introduced a helper method
Input::from_value.This fixes #1441.